import http from '@/utils/request.js';

// 获取专项保养详情
export const getspecials = (data) => {
	// return http.get('/repair/maintain/plan/content/special/type/detail',data);
	return http.request({
		url: '/repair/maintain/plan/content/special/type/detail',
		method: 'get',
		data,
	});
};

// 新增或修改专项检查项操作记录
export const setRecord = (data) => {
	// return http.post('/repair/special/history/record/save', data, 1);
	return http.request({
		url: '/repair/special/history/record/save',
		method: 'post',
		data,
		textJson: 1,
	});
};

// 新增或修改专项检查项图片视频描述
export const updataSpDate = (data) => {
	// return http.post('/repair/maintain/plan/content/special/history/update', data, 1);
	return http.request({
		url: '/repair/maintain/plan/content/special/history/update',
		method: 'post',
		data,
		textJson: 1,
	});
};

// 专项保养提交完成
export const finishData = (data) => {
	// return http.put(`/repair/maintain/plan/content/special/finish/${data.id}`, data, 1);
	return http.request({
		url: `/repair/maintain/plan/content/special/finish/${data.id}`,
		method: 'put',
		data,
		toast: 1,
	});
};

// 专项签字接口
export const signRecord = (data) => {
	// return http.post('/repair/maintain/plan/content/special/signature', data, 1);
	return http.request({
		url: '/repair/maintain/plan/content/special/signature',
		method: 'post',
		data,
		textJson: 1,
	});
};
